home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Nebula 1
/
Nebula One.iso
/
Utilities
/
Unix
/
CopyPath
/
README
< prev
Wrap
Text File
|
1992-01-07
|
4KB
|
105 lines
README for CopyPath (Version 1.3, 1-8-92)
One-line description:
Utility to set current directory in a shell from path in Workspace.
To NeXT archive maintainer:
This is a source package for NeXT OS 2.x. Please install
CopyPath_1.3.tar.Z in 2.0-release/source directory or equivalent.
Old versions of CopyPath may be deleted. Thank you.
************************************************************************
Intro:
If you use Terminal or Stuart, you might have wished for an easy way to
set current directory in a shell to that of Workspace. This was not
possible easily because of type mismatch of the pasteboard data between
Workspace and Terminal (or Stuart). Now, with CopyPath, this is a
two-keystroke operation: command-/ followed by command-v.
[OK, there is a cumbersome way of triple clicking the "path:" field
of Workspace's Inspector, but it won't give you a complete path
for a 'cd' command if the selection is on a directory.]
Command-/ creates a command "cd <current_directory_of_Workspace>" in
plain ascii pasteboard. You simply have to paste this into a shell
command line by command-v.
---
An example use:
You are in some directory far from root (/) in FileViewer of Workspace,
and don't want to bother figuring out the full pathname so you can 'cd'
there in a shell window. Instead, you press command-/ in the Workspace
FileViewer (Browser). This puts the full pathname of your current
location in that browser in a standard, recognizable form on the
pasteboard, so all you have to do is switch to the Terminal window
and press 'Paste' (Command-v).
Other applications, such as Edit and Librarian also use the pasteboard format
to paste the names of the files being referred to.
This app has no GUI.
CopyPath will continue to run until logout. It must be killed
via Tools/Processes panel, or kill <pid> from shell, if you
want to do so.
---
Installation:
make
cp CopyPath.daemon ~/Apps
[or as root: cp CopyPath.daemon /LocalApps]
If you are already using a version of CopyPath, you probably will
have to use the procedure below to force Workspace recognize
new services.
If Menus "Copy Path", "Copy cd Command /", and "Copy pushd Command"
don't appear in the services menu of Workspace Manager:
[1] Destroy ~/.NeXT/services/.applist and
~/.NeXT/services/.cache
To do this, use Workspace Manager or from a shell, do:
rm ~/.NeXT/services/{.applist,.cache}
[2] Logout Workspace and log back in.
[3] Launch "/NextApps/Terminal" (or Stuart if you use that).
[4] Type in Terminal
make_services
[5] Logout Workspace and log back in.
[The above should make the services menu appear correctly.]
Usage:
In Workspace, "Command-/" to generate a cd command on pasteboard.
[or "Services"->"Copy cd Command" on menu]
In Terminal (or Stuart) command line, do "Command-v" to paste in
the command.
Hit RETURN.
Interesting information:
Apparently, having .daemon at the end of exec filename prevents
its app icon from being displayed.
[That's a superficial effect; in fact, the entire -MachLaunch
protocol is circumvented. --EPS]
EPS has discovered TWO useful undocumented keywords that may be
used in a services specification (to be loaded into __services
section of the __ICON segment. CopyPath uses one of them.
Deactivate Requestor: YES (or NO)
Activate Provider: YES (or NO)
After a service request is sent to a service provider,
the service provider becomes the active application if YES.
Used by Workspace's "Open in Workspace" service.
---
No Copyright is claimed.
This program is hereby released into the public domain.
10-30-91, version 1.0 Izumi Ohzawa, izumi@pinoko.berkeley.edu
11-07-91, Condensed and modified by Daniel Faken, absinthe@u.washington.edu.
11-12-91, version 1.1 Izumi Ohzawa, some stuff grafted back.
11-20-91, version 1.2 Eric P. Scott, changed from Application to Listener;
numerous internal changes
1-08-92, version 1.3 Michael Cohen, mcohen@acoustic-srx1.ntt.jp
patched to allow multiple selection in browser
-----